package com.gitee.wsl.mathematics.vector.ext

import com.gitee.wsl.mathematics.vector.vec2.Vector2
import com.gitee.wsl.mathematics.vector.vec3.Vector3
import com.gitee.wsl.mathematics.vector.vec4.Vector4

infix fun <T:Number> Vector2<T, *>.approx(u: Vector2<T, *>): Boolean = x approx u.x && y approx u.y
infix fun <T:Number> Vector3<T, *>.approx(u: Vector3<T, *>): Boolean = x approx u.x && y approx u.y && z approx u.z
infix fun <T:Number> Vector4<T, *>.approx(u: Vector4<T, *>): Boolean = x approx u.x && y approx u.y && z approx u.z && w approx u.w

